package com.example.download.widget.loading

import android.content.Context
import android.util.AttributeSet
import android.view.LayoutInflater
import android.widget.FrameLayout
import com.example.download.R


/**
 * Created by  you
 * Date: 2022/3/30
 * Time: 17:09
 * 加载提示框
 */
class MiniVideoLoadingDialog @JvmOverloads constructor(
    context: Context,
    attributeSet: AttributeSet? = null,
    defaultSty: Int = 0
) : FrameLayout(context, attributeSet, defaultSty) {
    private lateinit var mLoadingView: CircularRing
    init {
      LayoutInflater.from(context).inflate(R.layout.minivideo_loading_dialog,this,true)
        mLoadingView = findViewById(R.id.loadingView)
    }



    fun show(){
        mLoadingView.startAnim()
    }
    fun hide(){
        mLoadingView.stopAnim()
    }
}